package booking

import (
	"car-thirdparty-api/api/booking/v1"
	"car-thirdparty-api/internal/service"
	"context"
)

func (c *ControllerV1) BookingAccess(ctx context.Context, req *v1.BookingAccessReq) (res *v1.BookingAccessRes, err error) {
	access, err := service.BookingV1().BookingAccess(ctx, req.BookingAccessReq)
	if err != nil {
		return nil, err
	}

	res = &v1.BookingAccessRes{
		BookingAccessRes: access,
	}

	return
}
